#!/bin/bash
#created by douyu
#for counting the size of memory which process used;
sum=0
for i in `ps aux |awk 'NR>1 {print $6}'`
do
  sum=$[ $sum + $i ]
done
echo "The total menmory is $sum kB"
